<?php if($title):?>
<h2><?php echo $title;?></h2>
<?php endif;?>
<?php 
$i = 0;
foreach($galleryItems as $galleryItem) 
{
	if(is_array($galleryItem) && isset($galleryItem[$model]))
	{
		$galleryItem = $galleryItem[$model];
	}
	if(strlen($galleryItem['name']) < 1)
		continue;
	if($i%$columns==0) echo "<div class='clr' ></div>"; ?>
	
 	<div class="galleryImage">
 		<?php echo $asset->preview($galleryItem, $imgOptions); ?>
	</div>
	
<?php $i++;
}
?>